# Maintainer: Antonio Rojas <arojas@archlinux.org>

pkgname=cauchy
pkgver=0.9.0
pkgrel=1
arch=(x86_64)
pkgdesc="A library for transforming Matlab/Octave files to C++ (with Eigen) and Matlab"
url="https://bitbucket.org/cyrille/cauchy"
license=(GPL2)
depends=(gcc-libs)
makedepends=(cmake eigen)
source=($pkgname-$pkgver.tar.bz2::"https://bitbucket.org/cyrille/cauchy/get/v$pkgver.tar.bz2")
sha256sums=('7a0cd9ef17190c09f271454b0e698e2e82172ce9efb9ef662e4f7134863d9b56')

prepare() {
  mkdir -p build
}

build() {
  cd build
  cmake ../cyrille-cauchy-* \
    -DCMAKE_BUILD_TYPE=Release \
    -DCMAKE_INSTALL_PREFIX=/usr
  make
}

package() {
  cd build
  make DESTDIR="$pkgdir" install
}
